#!/bin/sh

mkdir TestResults

baseURL=$1
WORKSPACE=${PWD}
REPORT_TEMPLATE=$WORKSPACE/ReportTemplate
TEST_CASE_PATH=$WORKSPACE/TestCases
TEST_RESULT_PATH=$WORKSPACE/TestResults
SCRIPT_PATH=$WORKSPACE/Script

rm -rf $TEST_RESULT_PATH/Allocate.*
rm -rf $TEST_RESULT_PATH/OMS.*
rm -rf $TEST_RESULT_PATH/pricecenter.*
rm -rf $TEST_RESULT_PATH/*.png

cd $TEST_CASE_PATH
ant -buildfile build_OMS.xml
#ant -buildfile build_Allocate.xml
#ant -buildfile build_pricecenter.xml
ant -buildfile build_new_pricecenter_consign.xml
ant -buildfile build_new_pricecenter_settle.xml
ant -buildfile build_new_pricecenter_settlecache.xml
ant -buildfile build_new_pricecenter_retail.xml
ant -buildfile build_new_pricecenter_retailcache.xml
#ant -buildfile build_kucun.xml

python $SCRIPT_PATH/GenReport.py $baseURL